#ifndef DIALOGEDITOR_H
#define DIALOGEDITOR_H

#include <QWidget>
#include <QColorDialog>
#include <QTextCharFormat>
#include "eventcenter.h"
namespace Ui {
class DialogEditor;
}

class DialogEditor : public QWidget
{
    Q_OBJECT

public:
    explicit DialogEditor(QWidget *parent = nullptr);
    ~DialogEditor();
    void Open(QString &name,QString &text);
private:
    Ui::DialogEditor *ui;
    QColorDialog colorDialog;
    QTextCharFormat tcf;
    bool selectName = false;
    void InitColor();
    void InitEditor();
public slots:
    void YesBtn();
};

#endif // DIALOGEDITOR_H
